﻿using Coldairarrow.Business.Base_Manage;
using Coldairarrow.Business.Interface;
using Coldairarrow.Entity.Base_Manage;
using Coldairarrow.Entity.DTO;
using Coldairarrow.Entity.Interface;
using Coldairarrow.Util;
using EFCore.Sharding;
using Microsoft.AspNetCore.Authorization;
using Microsoft.AspNetCore.Mvc;
using System;
using System.Collections.Generic;
using System.Threading.Tasks;

namespace Coldairarrow.Api.Controllers.Base_Manage
{
    /// <summary>
    /// 操作多平台订单
    /// </summary>
    [Route("/OpenApi/[controller]/[action]")]
    [AllowAnonymous]
   
    public class MultiPlatformOrdersController : BaseApiController
    {

        OL_MultiPlatformOrdersBusiness MultiPlatformOrders { get; }
        public MultiPlatformOrdersController(IDbAccessor db)
        {
            MultiPlatformOrders = new OL_MultiPlatformOrdersBusiness(db);
        }

        [HttpPost]
        public async Task<string> ZB_OrdersPush(List<ZB_ReqDTO_PushOrder> items)
        {
            return await MultiPlatformOrders.ZB_OrdersPush(items);
        }

        [HttpPost]
        public async Task<string> PL_OrdersPush(List<PL_ReqDTO_PushOrder> items)
        {
            return await MultiPlatformOrders.PL_OrdersPush(items);
        }

        [HttpPost]
        public async Task<string> ER_OrdersPush(List<RE_ReqDTO_Order> items)
        {
         return await MultiPlatformOrders.ER_OrdersPush(items);
        }
        [HttpPost]
        public async Task<string> ER_ReturnsPush(List<RE_ReqDTO_Return> items)
        {
            return await MultiPlatformOrders.ER_ReturnsPush(items);
        }
        [HttpPost]
        public async Task<string> EC_ReceivingPush(List<EC_ReqDTO_SyncReceiving.Biz_Content> items)
        {
            return await MultiPlatformOrders.EC_ReceivingPush(items);
        }


    }
}